
import type { ComponentImp } from "@/components/low-code/core/index";

export const componentMeta: ComponentImp[] = [
    //group:'base'
    {
        key: "",
        type: "button",
        name: "按钮",
        model: [],
        selector: "",
        group: 'base',
        describe: '',
        nestedChain: '',
        options: {
            name: '按钮',
            actionType: '',
            messageCode: '',
            onClickEvents: [],
        },
    },
    {
        key: "",
        type: "input",
        name: "输入框",
        model: [],
        selector: "",
        group: 'base',
        describe: '',
        nestedChain: '',
        options: {
            label: 'label',
            value: '',
            onChangeEvents: [],
            onFocusEvents: [],
            required: false,
            rules: []
        },
    },
    {
        key: "",
        type: "select",
        name: "下拉框",
        model: [],
        selector: "",
        group: 'base',
        describe: '',
        nestedChain: '',
        options: {
            label: 'label',
            value: '',
            required: false,
            rules: [],
            onChangeEvents: [],
        },
    },
    {
        key: "",
        type: "radio",
        name: "单选框",
        model: [],
        selector: "",
        group: 'base',
        describe: '',
        nestedChain: '',
        options: {
            label: 'label',
            value: '',
            required: false,
            rules: [],
            onChangeEvents: [],
        },
    },
    {
        key: "",
        type: "html",
        name: "HTML",
        model: [],
        selector: "",
        group: 'base',
        describe: '',
        nestedChain: '',
        options: {
            title: 'HTML',
            content: `<div style="color:red">自定义文本<div>`
        },
    },

    // group:'container'
    {
        key: "",
        type: "card",
        name: "卡片",
        model: [],
        selector: "",
        group: 'container',
        describe: '',
        nestedChain: '',
        options: {
            header: '卡片标题',
        },
        items: []
    },
    {
        key: "",
        type: "form",
        name: "表单域",
        model: [],
        selector: "",
        group: 'container',
        describe: '',
        nestedChain: '',
        options: {
            ref: null,
            labelWidth: 100,
            labelPosition: 'left',
            size: 'default'
        },
        items: []
    },
    {
        key: "",
        type: "row",
        name: "格栅",
        model: [],
        selector: "",
        group: 'container',
        describe: '',
        nestedChain: '',
        options: {
            gutter: 10
        },
        items: [
            {
                key: "NCQZYZGB",
                type: 'col',
                options: {
                    span: 12,
                    offset: 0
                },
                items: []
            },
            {
                key: "RSBQFXGA",
                type: 'col',
                options: {
                    span: 12,
                    offset: 0
                },
                items: []
            }
        ]
    },
    {
        key: "",
        type: "dialog",
        name: "弹框",
        model: [],
        selector: "",
        group: 'container',
        describe: '',
        nestedChain: '',
        options: {
            params: [
                {
                    key: 'id',
                    origin: '',
                    value: ''
                }
            ],
            visible: true,
            title: '弹框',
            alias: 'dialog',
            onShowEvents: [],
            onHideEvents: [],
        },
        items: []
    }
]



// {
//     key: "",
//     type: "dialog",
//     name: "弹框",
//     model: "",
//     group: 'container',
//     describe: '',
//     options: {
//         visible: false,
//     },
//     items: []
// }